@Inject('$http')
class PreviewTableService {

  get(id) {
    return this.$http({
      url: '/api/v1/commonForm/template/findOne',
      method: 'GET',
      params: id,
    });
  }

  query(param) {
    return this.$http.post('/api/v1/safetyTable/history/query', param);
  }

  delete(ids) {
    return this.$http.post('/api/v1/safetyTable/history/delete', ids);
  }

  getCanAction(workItemId) {
    return this.$http({
      url: '/api/workFlow/workItem/canAction',
      method: 'GET',
      params: workItemId,
    });
  }

}

export default PreviewTableService;
